<template>
  <div class="movie">
    <ul>
      <li v-for="(item,i) in movie" :key="i" >
        <img :src="item.pic" />
        <p>{{item.title}}</p>
        <p>{{item.descript}}</p>
      </li>
    </ul>
  </div>
</template>

<script>
import { getMovie } from "../../utils/api/home";
export default {
  name: "",
  data() {
    return {
      movie: [],
    };
  },
  created() {
    getMovie().then((res) => {
      this.movie = res;
    });
   
  },
  mounted() {},
  methods: {},
};
</script>

<style lang='scss' scoped>
.movie {
  width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
  ul {
    width: 35rem;
    display: flex;
    li {
      width: 7rem;
      height: 6rem;
      margin-left: 0.12rem;
      font-size: 0.26rem;

      p {
        width: 70%;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        margin-top: 0.2rem;
      }
      img {
        width: 100%;
        height: 80%;
        border-radius: 0.06rem;
      }
    }
  }
}
</style>